import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int n = scanner.nextInt();
        int m = scanner.nextInt();
        int l = scanner.nextInt();

        Solution solution = new Solution();

        System.out.println(solution.peopleAwareOfSecret(n, m, l));
    }
}

class Solution {
    public int peopleAwareOfSecret(int n, int delay, int forget) {
        int[][] dp = new int[n+1][forget];
        dp[1][0] = 1;
        for (int i = 2;i<=n;i++){
            for (int j = delay - 1;j <= forget - 2;j++){
                dp[i][0] = (dp[i][0] + dp[i - 1][j]) % 1000000007;
            }
            for (int j = 1; j < forget;j++){
                dp[i][j] = dp[i-1][j-1];
            }
        }
        int res = 0;
        for (int j = 0;j < forget;j++){
            res = (res + dp[n][j]) % 1000000007;
        }
        return res;
    }
}